<?php echo $this->render('common/header.phtml'); ?>
<!-- start content-outer ................................................................START -->
<div id="content-outer">
<!-- start content -->
<div id="content">

	<!--  start page-heading -->
	<div id="page-heading">
		<h1><?php if($this->id){?>Edit User<?php }else{?>Add User<?php }?></h1>
	</div>
	<!-- end page-heading -->

    <table border="0" width="100%" cellpadding="0" cellspacing="0" id="content-table">
        <tr>
            <th rowspan="3" class="sized"><img src="<?php echo $this->dirImg.'/shared/side_shadowleft.jpg'?>" width="20" height="300" alt="" /></th>
            <th class="topleft"></th>
            <td id="tbl-border-top">&nbsp;</td>
            <th class="topright"></th>
            <th rowspan="3" class="sized"><img src="<?php echo $this->dirImg.'/shared/side_shadowright.jpg'?>" width="20" height="300" alt="" /></th>
        </tr>
        <tr>
            <td id="tbl-border-left"></td>
            <td>
            <!--  start content-table-inner -->
        <div id="content-table-inner">
            <table border="0" width="100%" cellpadding="0" cellspacing="0">
                <tr valign="top">
                    <td>
						<?php 
                        if($this->error){	
                        ?>
                            <div id="message-red">
                            <table border="0" width="100%" cellpadding="0" cellspacing="0">
                            <?php foreach( $this->error as $val ){?>
                            <tr>
                                <td class="red-left"><?php echo $val;?></td>
                                <td class="red-right"><a class="close-red"><img src="<?php echo $this->dirImg.'/table/icon_close_red.gif' ?>"   alt="" /></a></td>
                            </tr>
                            <?php }?>
                            </table>
                            <br /><br /><br />
                            </div>
                        <?php
                        }elseif($this->successfully){
						?>
                            <!--  start message-green -->
                            <div id="message-green">
                            <table border="0" width="100%" cellpadding="0" cellspacing="0">
                            <tr>
                                <td class="green-left"><?php echo $this->successfully;?></td>
                                <td class="green-right"><a class="close-green"><img src="<?php echo $this->dirImg;?>/table/icon_close_green.gif"   alt="" /></a></td>
                            </tr>
                            </table>
                            <br /><br /><br />
                            </div>
                            <!--  end message-green -->
                        <?php	
						}
                        ?>                    
                        <!-- start id-form -->
                        <form name="add_user" method="post" action="<?php echo $this->baseUrl('admin/group/add');?>">
                        <table border="0" cellpadding="0" cellspacing="0"  id="id-form">
                        <tr>
                            <th valign="top">Name:</th>
                            <td><input type="text" name="name" class="inp-form-error" value="<?php echo $this->dataForm['name'];?>"/></td>
                            <td>
                                <div class="error-left"></div>
                                <div class="error-inner">This field is required.</div>
                            </td>
                        </tr>
                    <tr>
                        <th valign="top">Description:</th>
                        <td><textarea name="description" rows="" cols="" class="form-textarea"><?php if(isset($this->dataForm['description'])) echo $this->dataForm['description'];?></textarea></td>
                        <td></td>
                    </tr>
                    <tr>
                        <th>&nbsp;</th>
                        <td valign="top">
                        	<input type="hidden" name="id" value="<?php if(isset($this->id)) echo $this->id;?>" />
                            <input type="hidden" name="group_parent" value="0" />
                            <input type="submit" value="" class="form-submit" />
                            <input type="reset" value="" class="form-reset"  />
                        </td>
                        <td></td>
                    </tr>
                    </table>
                    	</form>
                    	<!-- end id-form  -->
                    
                    </td>
                    <td>
                        <!--  start related-activities -->
                        <div id="related-activities">
                            
                            <!--  start related-act-top -->
                            <div id="related-act-top">
                            	<img src="<?php echo $this->dirImg.'/forms/header_related_act.gif'?>" width="271" height="43" alt="" />
                            </div>
                            <!-- end related-act-top -->
                            
                            <!--  start related-act-bottom -->
                            <div id="related-act-bottom">
                            
                                <!--  start related-act-inner -->
                                <div id="related-act-inner">
                                    <div class="left"><a href=""><img src="<?php echo $this->dirImg.'/forms/icon_edit.gif'?>" width="21" height="21" alt="" /></a></div>
                                    <div class="right">
                                        <h5>List Group</h5>
                                        <ul class="greyarrow">
                                            <li><a href="<?php echo $this->baseUrl("admin/group/list");?>">Click here</a></li>
                                        </ul>
                                    </div>
                                    
                                    <div class="clear"></div>
                                    <div class="lines-dotted-short"></div>
                                    <div class="left"><a href=""><img src="<?php echo $this->dirImg.'/forms/icon_plus.gif'?>" width="21" height="21" alt="" /></a></div>
                                    <div class="right">
                                        <h5>Add another Group</h5>
                                        <ul class="greyarrow">
                                            <li><a href="<?php echo $this->baseUrl('admin/group/add');?>">Click here</a></li> 
                                        </ul>
                                    </div>
                                    
                                    <div class="clear"></div>
                                    <div class="lines-dotted-short"></div>
                                    
                                    <div class="left"><a href=""><img src="<?php echo $this->dirImg.'/forms/icon_minus.gif'?>" width="21" height="21" alt="" /></a></div>
                                    <div class="right">
                                        <h5>Delete this Group</h5>
                                        <ul class="greyarrow">
                                            <li><a class="deleteAdd" href="javascript:;">Click here</a></li> 
                                        </ul>
                                    </div>
                                    
                                    <div class="clear"></div>
                                    
                                </div>
                                <!-- end related-act-inner -->
                                <div class="clear"></div>
                            
                            </div>
                            <!-- end related-act-bottom -->
                        
                        </div>
                        <!-- end related-activities -->
                    </td>
                </tr>
                <tr>
                    <td><img src="<?php echo $this->dirImg.'/shared/blank.gif';?>" width="695" height="1" alt="blank" /></td>
                    <td></td>
                </tr>
            </table>
            
            <div class="clear"></div>
            
        
        </div>
        <!--  end content-table-inner  -->
        </td>
        <td id="tbl-border-right"></td>
        </tr>
        <tr>
            <th class="sized bottomleft"></th>
            <td id="tbl-border-bottom">&nbsp;</td>
            <th class="sized bottomright"></th>
        </tr>
    </table>
	<div class="clear">&nbsp;</div>

</div>
<!--  end content -->
<div class="clear">&nbsp;</div>
</div>
<!--  end content-outer........................................................END -->
<div class="noteDialog" style="display:none">
    <div class="deleteMessages"><?php echo $this->language->getMessages('en', 'deleteProduct');?></div>
</div>
<div class="clear">&nbsp;</div>
<?php echo $this->render('common/footer.phtml'); ?>   